export default [
  // 登录页面
  {
    //登录
    path: '/login',
    component: () => import('@/features/constant/login/Login.vue'),
    name: 'Login',
    meta: {
      title: '登录', //菜单标题
      hidden: true, //代表路由标题在菜单中是否隐藏  true:隐藏 false:不隐藏
      icon: 'Promotion', //菜单文字左侧的图标,支持element-plus全部图标
    },
  },
  // 首页
  {
    //登录成功以后展示数据的路由
    path: '/',
    component: () => import('@/features/constant/layout/PageLayout.vue'),
    name: 'Layout',
    meta: {
      title: '',
      hidden: false,
      icon: '',
    },
    redirect: '/home',
    children: [
      {
        path: '/home',
        name: 'Home',
        component: () => import('@/features/constant/home/Home.vue'),
        meta: {
          title: '首页',
          hidden: false,
          icon: 'HomeFilled',
        },
      },
    ],
  },
  // 404页面
  {
    //404
    path: '/404',
    component: () => import('@/features/constant/404/404.vue'),
    name: '404',
    meta: {
      title: '404',
      hidden: true,
      icon: 'DocumentDelete',
    },
  },
  // demo页面
  {
    path: '/demo',
    component: () => import('@/features/constant/layout/PageLayout.vue'),
    name: 'Demo',
    meta: {
      title: '组件演示',
      icon: 'Grid',
    },
    redirect: '/demo/components',
    children: [
      {
        path: '/demo/page',
        component: () => import('@/features/share/crudtemplate/Page.vue'),
        name: 'ComponentPages',
        meta: {
          title: 'CRUD页面',
          icon: 'User',
        },
      },
      {
        path: '/demo/components',
        component: () => import('@/components/crudstyle/ComponentDemo.vue'),
        name: 'ComponentDemo',
        meta: {
          title: 'CRUD组件',
          icon: 'ElementPlus',
        },
      },
      {
        path: '/demo/crud-table',
        component: () => import('@/components/crudstyle/CrudTable/demo.vue'),
        name: 'CrudTableDemo',
        meta: {
          title: 'CrudTable示例',
          icon: 'Grid',
        },
      },
      {
        path: '/demo/crud-data-table',
        component: () => import('@/components/cruddata/CrudDataTable/demo.vue'),
        name: 'CrudDataTableDemo',
        meta: {
          title: 'CrudDataTable示例',
          icon: 'Grid',
        },
      },
      {
        path: '/demo/crud-confirm-dialog',
        component: () => import('@/components/cruddata/CrudConfirmDialog/demo.vue'),
        name: 'CrudConfirmDialogDemo',
        meta: {
          title: 'CrudConfirmDialog示例',
          icon: 'MessageBox',
        },
      },
      {
        path: '/demo/crud-image-uploader',
        component: () =>
          import('@/components/crudstyle/CrudImageUploader/CrudImageUploaderDemo.vue'),
        name: 'CrudImageUploaderDemo',
        meta: {
          title: 'CrudImageUploader示例',
          icon: 'Upload',
        },
      },
    ],
  },
  // ========================异步路由
  // // 数据大屏
  // {
  //   path: '/screen',
  //   component: () => import('@/features/constant/layout/PageLayout.vue'),
  //   name: 'Screen',
  //   meta: {
  //     title: '数据大屏',
  //     icon: 'Platform',
  //   },
  //   redirect: '/screen/dashboard',
  //   children: [
  //     {
  //       path: 'dashboard',
  //       component: () => import('@/features/constant/home/Home.vue'),
  //       name: 'ScreenDashboard',
  //       meta: {
  //         title: '数据看板',
  //         icon: 'DataAnalysis',
  //       },
  //     },
  //   ],
  // },
  // // 权限管理
  // {
  //   path: '/acl',
  //   name: 'Acl',
  //   component: () => import('@/features/constant/layout/PageLayout.vue'),
  //   meta: {
  //     title: '权限管理',
  //     icon: 'Lock',
  //   },
  //   redirect: '/acl/user',
  //   children: [
  //     {
  //       path: 'user',
  //       component: () => import('@/features/common/acl/user/Page.vue'),
  //       name: 'User',
  //       meta: {
  //         title: '用户管理',
  //         icon: 'User',
  //       },
  //     },
  //     {
  //       path: 'role',
  //       component: () => import('@/features/common/acl/role/Page.vue'),
  //       name: 'Role',
  //       meta: {
  //         title: '角色管理',
  //         icon: 'UserFilled',
  //       },
  //     },
  //     {
  //       path: 'permission',
  //       component: () => import('@/features/common/acl/permission/Page.vue'),
  //       name: 'Permission',
  //       meta: {
  //         title: '菜单管理',
  //         icon: 'Monitor',
  //       },
  //     },
  //   ],
  // },
  // // 产品管理
  // {
  //   path: '/product',
  //   name: 'Product',
  //   component: () => import('@/features/constant/layout/PageLayout.vue'),
  //   meta: {
  //     title: '商品管理',
  //     icon: 'Goods',
  //   },
  //   redirect: '/product/trademark',
  //   children: [
  //     {
  //       path: 'trademark',
  //       component: () => import('@/features/crud/product/trademark/Page.vue'),
  //       name: 'Trademark',
  //       meta: {
  //         title: '品牌管理',
  //         icon: 'ShoppingCartFull',
  //       },
  //     },
  //   ],
  // },
]
